package com.alinesno.cloud.base.logger.entity;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import com.alibaba.fastjson.annotation.JSONField;


/**
 * <p>
 * 预警触发
 * </p>
 *
 * @author WeiXiaoJin
 * @since 2020-01-26 09:30:11
 */
@Entity
@Table(name="log_trigger")
public class LogTriggerEntity extends BaseWatcherEntity {

    private static final long serialVersionUID = 1L;

    /**
     * 触发器名称
     */
	@Column(name="trigger_name")
	private String triggerName;
    /**
     * 级别
     */
	@Column(name="trigger_severity")
	private String triggerSeverity;
    /**
     * 触发器类型
     */
	@Column(name="trigger_type")
	private String triggerType;
    /**
     * 开始时间
     */
	@Column(name="start_time")
	@JSONField(format="yyyy-MM-dd HH:mm:ss")
	private Date startTime;
    /**
     * 结束时间
     */
	@Column(name="end_time")
	@JSONField(format="yyyy-MM-dd HH:mm:ss")
	private Date endTime;
    /**
     * 持续时间(次)
     */
	@Column(name="continue_time")
	private Integer continueTime;

	/**
	 * 已通知次数
	 */
	@Column(name="has_run_time")
	private Integer hasRunTime;
	
    /**
     * 类名
     */
	@Column(name="class_name")
	private String className;
    /**
     * 触发关键字
     */
	@Column(name="trigger_keywork")
	private String triggerKeywork;
    /**
     * 触发阀值
     */
	@Column(name="trigger_value")
	private String triggerValue;

	/**
	 * 触发事件
	 */
	@Column(name="webhook")
	private String webhook ; 

	/**
	 * 事件类型
	 */
	@Column(name="alarm_event_type")
	private String alarmEventType ; 

	/**
	 * 通知邮件
	 */
	@Column(name="notice_email")
	private String noticeEmail ; 
	
	/**
	 * 通知短信
	 */
	@Column(name="notice_sms")
	private String noticeSms ; 

	/**
	 * 通知微信
	 */
	@Column(name="notice_wechat")
	private String noticeWechat ; 

	/**
	 * 通知钉钉
	 */
	@Column(name="notice_dingtalk")
	private String noticeDingTalk ; 

	public Integer getHasRunTime() {
		return hasRunTime;
	}

	public void setHasRunTime(Integer hasRunTime) {
		this.hasRunTime = hasRunTime;
	}

	public String getAlarmEventType() {
		return alarmEventType;
	}

	public void setAlarmEventType(String alarmEventType) {
		this.alarmEventType = alarmEventType;
	}

	public String getNoticeEmail() {
		return noticeEmail;
	}

	public void setNoticeEmail(String noticeEmail) {
		this.noticeEmail = noticeEmail;
	}

	public String getNoticeSms() {
		return noticeSms;
	}

	public void setNoticeSms(String noticeSms) {
		this.noticeSms = noticeSms;
	}

	public String getNoticeWechat() {
		return noticeWechat;
	}

	public void setNoticeWechat(String noticeWechat) {
		this.noticeWechat = noticeWechat;
	}

	public String getNoticeDingTalk() {
		return noticeDingTalk;
	}

	public void setNoticeDingTalk(String noticeDingTalk) {
		this.noticeDingTalk = noticeDingTalk;
	}

	public String getWebhook() {
		return webhook;
	}

	public void setWebhook(String webhook) {
		this.webhook = webhook;
	}

	public String getTriggerName() {
		return triggerName;
	}

	public void setTriggerName(String triggerName) {
		this.triggerName = triggerName;
	}

	public String getTriggerSeverity() {
		return triggerSeverity;
	}

	public void setTriggerSeverity(String triggerSeverity) {
		this.triggerSeverity = triggerSeverity;
	}

	public String getTriggerType() {
		return triggerType;
	}

	public void setTriggerType(String triggerType) {
		this.triggerType = triggerType;
	}

	public Date getStartTime() {
		return startTime;
	}

	public void setStartTime(Date startTime) {
		this.startTime = startTime;
	}

	public Date getEndTime() {
		return endTime;
	}

	public void setEndTime(Date endTime) {
		this.endTime = endTime;
	}

	public Integer getContinueTime() {
		return continueTime;
	}

	public void setContinueTime(Integer continueTime) {
		this.continueTime = continueTime;
	}

	public String getClassName() {
		return className;
	}

	public void setClassName(String className) {
		this.className = className;
	}

	public String getTriggerKeywork() {
		return triggerKeywork;
	}

	public void setTriggerKeywork(String triggerKeywork) {
		this.triggerKeywork = triggerKeywork;
	}

	public String getTriggerValue() {
		return triggerValue;
	}

	public void setTriggerValue(String triggerValue) {
		this.triggerValue = triggerValue;
	}


	@Override
	public String toString() {
		return "LogTriggerEntity{" +
			"triggerName=" + triggerName +
			", triggerSeverity=" + triggerSeverity +
			", triggerType=" + triggerType +
			", startTime=" + startTime +
			", endTime=" + endTime +
			", continueTime=" + continueTime +
			", className=" + className +
			", triggerKeywork=" + triggerKeywork +
			", triggerValue=" + triggerValue +
			"}";
	}
}
